home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus Leser 19 / Amiga Plus Leser CD 19.iso / Tools / MorphOS / cvs-1.11.2 / source / amiga / ssh / md5.h < prev    next >
Encoding:
C/C++ Source or Header  |  2002-11-18  |  928 b   |  44 lines

  1. /*
  2.  * MD5 hash structures and functions
  3.  *
  4.  * $Id$
  5.  *
  6.  * :ts=4
  7.  */
  8.  
  9. #ifndef _MD5_H
  10. #define _MD5_H
  11.  
  12. /****************************************************************************/
  13.  
  14. #ifdef _SSH
  15. #define MD5Init        SSH_MD5Init
  16. #define MD5Update    SSH_MD5Update
  17. #define MD5Final    SSH_MD5Final
  18. #endif /* _SSH */
  19.  
  20. /****************************************************************************/
  21.  
  22. typedef struct
  23. {
  24.     unsigned long h[4];
  25. } MD5_Core_State;
  26.  
  27. typedef struct MD5Context
  28. {
  29.     MD5_Core_State core;
  30.     unsigned char block[64];
  31.     int blkused;
  32.     unsigned long lenhi, lenlo;
  33. } MD5Context;
  34.  
  35. /****************************************************************************/
  36.  
  37. void MD5Init(struct MD5Context *s);
  38. void MD5Update(struct MD5Context *s, unsigned char const *p, unsigned len);
  39. void MD5Final(unsigned char output[16], struct MD5Context *s);
  40.  
  41. /****************************************************************************/
  42.  
  43. #endif /* _MD5_H */
  44.